package com.ruoyi.tag.domain;

import java.time.LocalDate;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 帖子与标签中间表对象 post_tags_rel
 * 
 * @author ruoyi
 * @date 2025-06-17
 */
@Schema(description = "帖子与标签中间表对象")
public class PostTagsRel extends BaseEntity
{
    private static final long serialVersionUID = 1L;


    /** 自增ID */
    @Schema(title = "自增ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    /** 帖子ID */
    @Schema(title = "帖子ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long postId;

    /** 标签ID */
    @Schema(title = "标签ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long tagId;

    /** 创建时间 */
    @Schema(title = "创建时间")
    private LocalDate createdTime;
    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }


    public void setPostId(Long postId) 
    {
        this.postId = postId;
    }

    public Long getPostId() 
    {
        return postId;
    }


    public void setTagId(Long tagId) 
    {
        this.tagId = tagId;
    }

    public Long getTagId() 
    {
        return tagId;
    }


    public void setCreatedTime(LocalDate createdTime) 
    {
        this.createdTime = createdTime;
    }

    public LocalDate getCreatedTime() 
    {
        return createdTime;
    }



    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("postId", getPostId())
            .append("tagId", getTagId())
            .append("createdTime", getCreatedTime())
            .toString();
    }
}
